window: Only draw the resize grip if it is actually visible
authorBenjamin Otte <otte@redhat.com>
Sat, 16 Apr 2011 19:48:05 +0000 (21:48 +0200)
committerBenjamin Otte <otte@redhat.com>
Sat, 16 Apr 2011 20:31:24 +0000 (22:31 +0200)
This issue can only be seen if someone calls gtk_widget_draw() on the
window as otherwise gtk_cairo_should_draw_window() would return FALSE.

gtk/gtkwindow.c

index ae2aa688af95eafeacdd62c925fe23512b694b0a..b04666961952857d2bc0f62b77b1dd2555293496 100644 (file)
@@ -7304,7 +7304,7 @@ gtk_window_draw (GtkWidget *widget,
   if (GTK_WIDGET_CLASS (gtk_window_parent_class)->draw)
     ret = GTK_WIDGET_CLASS (gtk_window_parent_class)->draw (widget, cr);
 
-  if (priv->grip_window != NULL &&
+  if (priv->resize_grip_visible &&
       gtk_cairo_should_draw_window (cr, priv->grip_window))
     {
       GdkRectangle rect;